﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.ServiceModel.Web;
using System.Text;
using AuctionHouseDataLibrary;

namespace ItemDatabase
{
    [ServiceContract]
    public interface IItemDatabaseService
    {
        [OperationContract]
        Item GetItem(int itemId);

        [OperationContract]
        List<Item> GetItems(List<int> itemIds);

        [OperationContract]
        [WebGet(RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        string GetImagesFolder();

        [OperationContract]
        [WebGet(RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        void AddOrUpdateRecurringAHScan(string realm, bool alliance, bool horde, bool neutral, int minutesBetweenScans);

        [OperationContract]
        [WebGet(RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        void RemoveRecurringAHScan(string realm);

        [OperationContract]
        [WebGet(RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        List<RecurringAHScan> ListAllRecurringAHScans();

        [OperationContract]
        [WebGet(RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        PagedData<Item> GetItemsForDisplay(string name, int page, int start, int limit, string sort, string dir);
    }
}
